using Microsoft.Xna.Framework;
using Microsoft.Xna.Framework.Graphics;

namespace MechaShark
{
    public struct VertexPositionNormal : IVertexType //custum Vertex type, contains no texture coord.  Only position and normal.
    {
        //-------------Members-------------
        public Vector3 Position;
        public Vector3 Normal;

        //-------------Methods-------------
        //constuctor
        public VertexPositionNormal(Vector3 position, Vector3 normal)
        {
            Position = position;
            Normal = normal;
        }

        /// <summary>
        /// A VertexDeclaration object, which contains information about the vertex
        /// elements contained within this struct.
        /// </summary>
        public static readonly VertexDeclaration VertexDeclaration = new VertexDeclaration
       (
           new VertexElement(0, VertexElementFormat.Vector3, VertexElementUsage.Position, 0),
           new VertexElement(12, VertexElementFormat.Vector3, VertexElementUsage.Normal, 0)
       );

        VertexDeclaration IVertexType.VertexDeclaration
        {
            get { return VertexPositionNormal.VertexDeclaration; }
        }

    }
}
